package org.onepiece.admin.common.config.yaml;

import com.alibaba.fastjson2.JSON;
import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * Created by IntelliJ IDEA.
 *
 * @author zhujianke@gaodun.com
 * @since 2022/10/28 11:57
 */
@Component
@PropertySource(value = {"classpath:config/allocation-score.yaml"}, factory = YamlPropertySourceFactory.class)
@ConfigurationProperties(prefix = "allocation-score")
@Data
public class AllocationRuleScoreProperties {

    private Integer country;

    private Integer province;

    private Integer city;

    @Override
    public String toString() {
        return JSON.toJSONString(this);
    }



}
